package com.example.basic;



public class RaceRun implements Runnable{
    @Override
    public void run() {
        int i=1;
        while (i<100){
            for (i = 1; i <= 100; i++) {
                System.out.println(Thread.currentThread().getName()+"跑了"+i);
            }
        }

    }

    public static void main(String[] args) {
        RaceRun raceRun = new RaceRun();
        Thread rabbit = new Thread(raceRun, "兔子");
        Thread gui = new Thread(raceRun, "乌龟");
        rabbit.start();
        gui.start();
    }
}
